package com.example.ovulationperiodtracker.Allactivity;

import android.annotation.SuppressLint;
import android.content.DialogInterface;
import android.content.Intent;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuItem;

import androidx.appcompat.app.AppCompatActivity;

import com.afollestad.materialdialogs.MaterialDialog;
import com.example.ovulationperiodtracker.databinding.ActivityOvulationBinding;
import com.example.ovulationperiodtracker.utils.JCGSQLiteHelper;
import com.example.ovulationperiodtracker.R;
import com.example.ovulationperiodtracker.model.Settings;
import com.example.ovulationperiodtracker.view.NavigationView;
import com.example.ovulationperiodtracker.view.NoteUtils;
import com.necer.base.BaseActivity;
import com.shawnlin.numberpicker.NumberPicker;

public class OvulationActivity extends BaseActivity<ActivityOvulationBinding> {



    @Override
    protected ActivityOvulationBinding createBinding(LayoutInflater inflater) {
        return ActivityOvulationBinding.inflate(inflater);
    }

    @Override
    protected void onCreated(Bundle savedInstanceState) {

        binding.navigation.setOnClickRightListener(new NavigationView.OnClickRightListener() {
            @Override
            public void onClickRight() {
                int value = binding.numberPicker.getValue();
                NoteUtils.saveHuangTiQi(value);
                finish();
            }
        });

        int huangTiQi = NoteUtils.getHuangTiQi();
        binding.numberPicker.setValue(huangTiQi);

    }


}
